<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org" class="h-100">
<head>
	<meta charset="utf-8">
	<meta http-equiv="x-ua-compatible" content="ie=edge">
	<title>Add / Edit Employee</title>
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="stylesheet" href="https://cdn.bootcss.com/twitter-bootstrap/4.3.1/css/bootstrap.min.css"/>
	<script src="https://cdn.bootcss.com/jquery/3.4.1/jquery.slim.min.js"></script>
	<script src="https://cdn.bootcss.com/twitter-bootstrap/4.3.1/js/bootstrap.min.js"></script>
	<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.4.1/css/all.css">
	<style>
		main > .container {
			padding: 60px 15px 0;
		}
		.footer {
			background-color: #f5f5f5;
		}
	</style>
</head>
<body>
	<header>
		<nav class="navbar navbar-expand-md navbar-dark bg-dark fixed-top">
			<a class="navbar-brand" th:href="@{/}">Spring Boot 2</a>
			<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarsExampleDefault" aria-controls="navbarsExampleDefault" aria-expanded="false" aria-label="Toggle navigation">
				<span class="navbar-toggler-icon"></span>
			</button>
			<div class="collapse navbar-collapse" id="navbarsExampleDefault">
				<ul class="navbar-nav mr-auto">
					<li class="nav-item active">
						<a class="nav-link" th:href="@{/}">Home <span class="sr-only">(current)</span></a>
					</li>
					<li class="nav-item">
						<a class="nav-link" href="https://github.com/T5750/framework-repositories" target="_blank">GitHub</a>
					</li>
					<li class="nav-item">
						<a class="nav-link" href="https://t5750.github.io/" target="_blank">Blog</a>
					</li>
				</ul>
			</div>
		</nav>
	</header>
	<main role="main" class="flex-shrink-0">
		<div class="container my-3">
			<h3> Add / Edit Employee</h3>
			<div class="card">
				<div class="card-body">
					<div class="col-md-10">
						<form action="#" th:action="@{/employeePage/saveOrUpdate}" th:object="${employee}" method="post">
							<div class="row">
								<div class="form-group col-md-8">
									<label for="firstName" class="col-form-label">First Name</label>
									<input type="text" th:field="*{firstName}" class="form-control"
										   id="firstName" placeholder="First Name"/>
								</div>
								<div class="form-group col-md-8">
									<label for="lastName" class="col-form-label">Last Name</label>
									<input type="text" th:field="*{lastName}" class="form-control"
										   id="lastName" placeholder="Last Name"/>
								</div>
								<div class="form-group col-md-8">
									<label for="email" class="col-form-label">Email</label>
									<input type="text" th:field="*{email}" class="form-control"
										   id="email" placeholder="Email Id"/>
								</div>
								<div class="col-md-6">
									<input type="submit" class="btn btn-primary" value=" Submit ">
								</div>
								<input type="hidden" id="id" th:field="*{id}">
							</div>
						</form>
					</div>
				</div>
			</div>
		</div>
	</main>
	<footer class="footer mt-auto py-3">
		<div class="container">
			<span class="text-muted">© 2019 T5750</span>
		</div>
	</footer>
</body>
</html>